
#include "Login.hpp"


/**
 * 模块ID
 */
const uint16_t Login::messageId = 0 ;
Login::Login() {
	account = "" ;
	password = "" ;
} ;

Login::~Login() {
} ;

CMsgTyped* Login::Unserialize( CMsgTyped* msgTyped ) {
	account = msgTyped->StringVal() ;
	password = msgTyped->StringVal() ;
	return msgTyped ;
} ;

const uint16_t Logout::messageId = 1 ;
Logout::Logout() {
	account = "" ;
	password = "" ;
} ;

Logout::~Logout() {
} ;

CMsgTyped* Logout::Unserialize( CMsgTyped* msgTyped ) {
	account = msgTyped->StringVal() ;
	password = msgTyped->StringVal() ;
	return msgTyped ;
} ;

const uint16_t LoginRespon::messageId = 0 ;

LoginRespon::LoginRespon() {
	errorCode = 0 ;
	acctInfo = "" ;
} ;

LoginRespon::~LoginRespon() {
} ;

CMsgTyped* LoginRespon::Serialize( CMsgTyped * msgTyped ) {
	msgTyped->SetInt( errorCode ) ;
	msgTyped->SetString( acctInfo.c_str( ) ) ;
	return msgTyped ;
} ;

const uint16_t LogoutRespon::messageId = 1 ;

LogoutRespon::LogoutRespon() {
	errorCode = 0 ;
} ;

LogoutRespon::~LogoutRespon() {
} ;

CMsgTyped* LogoutRespon::Serialize( CMsgTyped * msgTyped ) {
	msgTyped->SetInt( errorCode ) ;
	return msgTyped ;
} ;

